<?php
/**
 * Enter description here ...
 * @author Micou13630
 *
 */
class RequestDao implements IRequestDao {
	private $fields = array();
	
	/**
	 * Enter description here ...
	 * @param HttpRequest $req
	 */
	public function RequestDao(HttpRequest $req) {
		// Traitement des proprietes
		$prop = get_object_vars($req);
		foreach ($prop as $key=>$val) {
			if (substr($key, 0, 1) != '_' && substr($key, 0, 4) != 'isc_' && substr($key, 0, 1) != '%' 
				&& substr($key, 0, 1) != '$' && substr($key, 0, 8) != 'children') {
				$this->fields[$key] = $val;
			} else {
				$this->$key = $val;
			}
		}
	}
	
	/**
	 * Renvoie l'operation
	 */
	public function getOperationType() {
		return $this->_operationType;
	}
	
	/**
	 * Renvoie les champs
	 */
	public function getFieldsValue() {
		return $this->fields;
	}
	
	/**
	 * Renvoie le sort
	 */
	public function getSort() {
		return null;
	}
	
	/**
	 * Renvoie le filtre
	 */
	public function getFilter() {
		return null;
	}
	
	/**
	 * Renvoie startRow
	 */
	public function getStartRow() {
		return $this->_startRow;
	}
	
	/**
	 * Renvoie endRow
	 */
	public function getEndRow() {
		return $this->_endRow;
	}
	
	/**
	 * Renvoie textMatchStyle
	 */
	public function getTextMatchStyle() {
		return $this->_textMatchStyle;
	}
	
}
?>